feat: Add support for rest scan planning#2864
Merged
Fokko merged 2 commits intoapache:mainfrom Jan 16, 2026
Merged
Conversation
singhpk234
reviewed
Jan 5, 2026
Fokko
reviewed
Jan 12, 2026
Fokko
reviewed
Jan 12, 2026
pyiceberg/table/__init__.py
Outdated
Comment on lines
2054
to
2060
| def _should_use_rest_planning(self) -> bool: | ||
| """Check if REST scan planning should be used for this scan.""" | ||
| from pyiceberg.catalog.rest import RestCatalog | ||
|
|
||
| if not isinstance(self.catalog, RestCatalog): | ||
| return False | ||
| return self.catalog.is_rest_scan_planning_enabled() |
Contributor
There was a problem hiding this comment.
I would be inclined to create a method on the Catalog, eg:
@property
@abstractmethod
def use_server_side_planning(self, identifier: str | Identifier) -> bool:
"""Support for Server Side Planning"""
Have the MetastoreCatalog implement it, and return False. And rename is_rest_scan_planning_enabled to support_server_side_planning. Now we have to go though multiple jumps.
This would also clean up _plan_files_rest below.
Fokko
reviewed
Jan 12, 2026
Fokko
reviewed
Jan 12, 2026
10 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
related to #2775
Rationale for this change
Adds synchornous client-side support for REST server side scan planning, allowing for scanning if the rest catalog supports it.
This PR cherry-picks and builds on two WIP PRs:
Currently scanning is enable with rest-scan-planning-enabled=true in catalog properties.
TODO: spec handling
Are these changes tested?
Integration tests added with manual testing
Are there any user-facing changes?
yes